package geektime.spring.springbucks.datatransaction;

import org.springframework.transaction.annotation.Transactional;

public interface FooService {
    void insertRecord();
    void insertThenRollback() throws RollbackException;

    @Transactional(rollbackFor = RollbackException.class)
    void deleteThenRollback() throws RollbackException;

    @Transactional(rollbackFor = RollbackException.class)
    void updateThenRollback() throws RollbackException;

    void invokeInsertThenRollback() throws RollbackException;
}
